<include file="public@header"/>
</head>
<body>
<div class="wrap">
    <ul class="nav nav-tabs">
        <li class="active"><a>联系单</a></li>
        <li><a href="{:url('contact/add',array('id'=>$id))}">新增联系单</a></li>
    </ul>
    <form class="well form-inline js-ajax-form margin-top-20" method="post" action="{:url('contact/search')}">
        流程完成情况:
        <select name="status" class="form-control">
            <option value=""></option>
            <option value="1">完成</option>
            <option value="2">未完成</option>
            <option value="3">私了</option>
            <option value="4">作废</option>
        </select>
        <input type="hidden" name="id" value="{$id}">
        <!--        <input   type="text" class="form-control" name="type" style="width: 120px;"-->
        <!--               value="{:input('request.user_login/s','')}" placeholder="请输入{:lang('USERNAME')}">-->
        <button type="submit" class="btn btn-primary ">搜索</button>
        <a class="btn btn-danger" href="">清空</a>

    </form>
    <form method="post" class="js-ajax-form margin-top-20">
        <table class="table table-hover table-bordered">
            <thead>
            <tr>
                <th>送审时间</th>
                <th>联系单名称</th>
                <th>描述</th>
                <th>金额</th>
                <th>流程完成情况</th>
                <th>{:lang('ACTIONS')}</th>
            </tr>
            </thead>
            <tbody>
            <volist name="res" id="v">
            <tr>
                <td>{$v.subTime}</td>
                <td>{$v.title}</td>
                <td>{$v.desc}</td>
                <td>{$v.price}</td>
                <td>
                    <?php
                        if($v['status'] == 1){
                    ?>
                    <span class="label label-success">完成</span>
                    <?php
                        }elseif($v['status'] == 2){
                    ?>
                    <span class="label label-danger">未完成</span>

                    <?php
                        }elseif($v['status'] == 3){
                    ?>
                    <span class=" label label-success">私了</span>
                    <?php
                        }elseif($v['status'] == 4){
                    ?>
                    <span class="label label-default">作废</span>

                    <?php
                        }
                    ?>
                </td>
                <td>
                    <a class="btn btn-xs btn-primary js-ajax-submit"
                       href="{:url('contact/see',array('id'=>$v['id']))}">查看详情</a>
                    <a class="btn btn-xs btn-danger js-ajax-delete" class=""
                       href="{:url('contact/del',array('id'=>$v['id']))}">{:lang('DELETE')}</a>
                </td>
            </tr>
            </volist>
            </tbody>
        </table>

    </form>
</div>
<script src="__STATIC__/js/admin.js"></script>
</body>
</html>